const mongoose=require("mongoose");
const Schema=mongoose.Schema;

mongoose.connect("mongodb://127.0.0.1:27017/feiji",{
    useNewUrlParser:true,
    useUnifiedTopology:true
})

let recommendSchema=new Schema({
    category:{
        type:String,
        require:true
    },
    categoryList:[
        {
            id:{
                type:String,
                require:true
            },
            cover:{
                type:String,
                require:true
            },
            title:{
                type:String,
                require:true
            }
        }
    ]
})

let recommendDatas=mongoose.model("recommendDatas",recommendSchema)

module.exports={
    recommendTable:recommendDatas
}